package com.shuiyun.jtt.message.mapping;

import com.shuiyun.jtt.message.schema.*;

/**
 * @author shuiyun
 * @program gateway
 * @description 终端参数映射
 * @date 2022-05-09 23:51
 **/
public class TerminalParamMapping extends DataTypeMapping {

    @Override
    protected void addSchemas(DataTypeMapping schemaRegistry) {
        schemaRegistry
                .addMapping(0x0001, DWordSchema.INSTANCE)
                .addMapping(0x0002, DWordSchema.INSTANCE)
                .addMapping(0x0003, DWordSchema.INSTANCE)
                .addMapping(0x0004, DWordSchema.INSTANCE)
                .addMapping(0x0005, DWordSchema.INSTANCE)
                .addMapping(0x0006, DWordSchema.INSTANCE)
                .addMapping(0x0007, DWordSchema.INSTANCE)
                // 0x008~0x000F 保留
                .addMapping(0x0010, StringSchema.INSTANCE)
                .addMapping(0x0011, StringSchema.INSTANCE)
                .addMapping(0x0012, StringSchema.INSTANCE)
                .addMapping(0x0013, StringSchema.INSTANCE)
                .addMapping(0x0014, StringSchema.INSTANCE)
                .addMapping(0x0015, StringSchema.INSTANCE)
                .addMapping(0x0016, StringSchema.INSTANCE)
                .addMapping(0x0017, StringSchema.INSTANCE)
                // 0x0018~0x0019 保留
                .addMapping(0x001A, StringSchema.INSTANCE)
                .addMapping(0x001B, DWordSchema.INSTANCE)
                .addMapping(0x001C, DWordSchema.INSTANCE)
                .addMapping(0x001D, StringSchema.INSTANCE)
                // 0x001e~0x001f 保留
                .addMapping(0x0020, DWordSchema.INSTANCE)
                .addMapping(0x0021, DWordSchema.INSTANCE)
                .addMapping(0x0022, DWordSchema.INSTANCE)
                .addMapping(0x0023, StringSchema.INSTANCE)
                .addMapping(0x0024, StringSchema.INSTANCE)
                .addMapping(0x0025, StringSchema.INSTANCE)
                .addMapping(0x0026, StringSchema.INSTANCE)
                .addMapping(0x0027, DWordSchema.INSTANCE)
                .addMapping(0x0028, DWordSchema.INSTANCE)
                .addMapping(0x0029, DWordSchema.INSTANCE)
                // 0x002a~0x002b 保留
                .addMapping(0x002C, DWordSchema.INSTANCE)
                .addMapping(0x002D, DWordSchema.INSTANCE)
                .addMapping(0x002E, DWordSchema.INSTANCE)
                .addMapping(0x002F, DWordSchema.INSTANCE)
                .addMapping(0x0030, DWordSchema.INSTANCE)
                .addMapping(0x0031, WordSchema.INSTANCE)
                .addMapping(0x0032, BytesSchema.INSTANCE)
                // 0x0033~ 0x003f 保留
                .addMapping(0x0040, StringSchema.INSTANCE)
                .addMapping(0x0041, StringSchema.INSTANCE)
                .addMapping(0x0042, StringSchema.INSTANCE)
                .addMapping(0x0043, StringSchema.INSTANCE)
                .addMapping(0x0044, StringSchema.INSTANCE)
                .addMapping(0x0045, DWordSchema.INSTANCE)
                .addMapping(0x0046, DWordSchema.INSTANCE)
                .addMapping(0x0047, DWordSchema.INSTANCE)
                .addMapping(0x0048, StringSchema.INSTANCE)
                .addMapping(0x0049, StringSchema.INSTANCE)
                // 0x004A~0x004f 保留
                .addMapping(0x0050, DWordSchema.INSTANCE)
                .addMapping(0x0051, DWordSchema.INSTANCE)
                .addMapping(0x0052, DWordSchema.INSTANCE)
                .addMapping(0x0053, DWordSchema.INSTANCE)
                .addMapping(0x0054, DWordSchema.INSTANCE)
                .addMapping(0x0055, DWordSchema.INSTANCE)
                .addMapping(0x0056, DWordSchema.INSTANCE)
                .addMapping(0x0057, DWordSchema.INSTANCE)
                .addMapping(0x0058, DWordSchema.INSTANCE)
                .addMapping(0x0059, DWordSchema.INSTANCE)
                .addMapping(0x005A, DWordSchema.INSTANCE)
                .addMapping(0x005B, WordSchema.INSTANCE)
                .addMapping(0x005C, WordSchema.INSTANCE)
                .addMapping(0x005D, WordSchema.INSTANCE)
                .addMapping(0x005E, WordSchema.INSTANCE)
                // 0x005f~0x006f 保留
                .addMapping(0x0064, DWordSchema.INSTANCE)
                .addMapping(0x0065, DWordSchema.INSTANCE)
                // 0x0066~0x006f 保留
                .addMapping(0x0070, DWordSchema.INSTANCE)
                .addMapping(0x0071, DWordSchema.INSTANCE)
                .addMapping(0x0072, DWordSchema.INSTANCE)
                .addMapping(0x0073, DWordSchema.INSTANCE)
                .addMapping(0x0074, DWordSchema.INSTANCE)
                // 0x0075~0x007f 保留
                .addMapping(0x0080, DWordSchema.INSTANCE)
                .addMapping(0x0081, WordSchema.INSTANCE)
                .addMapping(0x0082, WordSchema.INSTANCE)
                .addMapping(0x0083, StringSchema.INSTANCE)
                .addMapping(0x0084, ByteSchema.INSTANCE)

                .addMapping(0x0090, ByteSchema.INSTANCE)
                .addMapping(0x0091, ByteSchema.INSTANCE)
                .addMapping(0x0092, ByteSchema.INSTANCE)
                .addMapping(0x0093, DWordSchema.INSTANCE)
                .addMapping(0x0094, ByteSchema.INSTANCE)
                .addMapping(0x0095, DWordSchema.INSTANCE)

                .addMapping(0x0100, DWordSchema.INSTANCE)
                .addMapping(0x0101, WordSchema.INSTANCE)
                .addMapping(0x0102, DWordSchema.INSTANCE)
                .addMapping(0x0103, WordSchema.INSTANCE)

                .addMapping(0x0110, BytesSchema.INSTANCE)
                .addMapping(0x0111, BytesSchema.INSTANCE)
                .addMapping(0x0112, BytesSchema.INSTANCE)
                .addMapping(0x0113, BytesSchema.INSTANCE)
                .addMapping(0x0114, BytesSchema.INSTANCE)
                .addMapping(0x0115, BytesSchema.INSTANCE)
                .addMapping(0x0116, BytesSchema.INSTANCE)
                .addMapping(0x0117, BytesSchema.INSTANCE)
                .addMapping(0x0118, BytesSchema.INSTANCE)
                .addMapping(0x0119, BytesSchema.INSTANCE)
                .addMapping(0x011A, BytesSchema.INSTANCE)
                .addMapping(0x011B, BytesSchema.INSTANCE)
                .addMapping(0x011C, BytesSchema.INSTANCE)
                .addMapping(0x011D, BytesSchema.INSTANCE)
                .addMapping(0x011E, BytesSchema.INSTANCE)
                .addMapping(0x011F, BytesSchema.INSTANCE);
    }
}
